;; (require 'yasnippet-bundle)

;; (yas/initialize)
;; (yas/load-directory "~/.emacs.d/snippets")
;; ;; I don't like using partial words for completion
;; (setq yas/key-syntaxes '("w_" "w_." "^ "))

;; (defun sacha/drupal-module-name ()
;;   "Return the Drupal module name for .module and .install files."
;;   (file-name-sans-extension (file-name-nondirectory (buffer-file-name))))

;; (defun sacha/drupal-module-update-number ()
;;   "Return the number of the next module update function.
;; This is one more than the highest number used so far.
;; This function should be called in a module's .install file."
;;   (save-excursion
;;     (save-restriction
;;       (widen)
;;       (goto-char (point-min))
;;       (let ((module-name (sacha/drupal-module-name))
;; 	    (max 0))
;; 	(while (re-search-forward
;; 		(concat "function[ \t\n]+" module-name "_update_\\([0-9]+\\)") nil t)
;; 	  (setq max (max (string-to-number (match-string 1)) max)))
;; 	(number-to-string (1+ max))))))

;; (add-to-list 'load-path "~/.emacs.d/libs/yasnippet")
;; (require 'yasnippet) ;; not yasnippet-bundle
;; (yas/initialize)
;; (yas/load-directory "~/.emacs.d/libs/yasnippet/snippets")
